<?php

require_once('inc.config.php');

$useTemplate   = 'agent_admin_rhlist.html';

$page = new QuickSkin ($useTemplate );

template_ini($page);

$condition = array("aid" =>__user_id__);

$order = $_REQUEST["order"];
if(!isset($order)){$order=1;}

$infoid = $_REQUEST["infoid"];
if(!isset($infoid)){$infoid="";}

$ispublic = $_REQUEST["ispublic"];
if(!isset($ispublic)){$ispublic=0;}

$p = $_REQUEST["r_page"];
if(!isset($p)){$p=1;}

if(__user_prop__=="0"){
	$condition = array(
		"aid" => __user_id__,
		"prop" => __user_prop__,
		"infoid" => $infoid,
		"type" => $type,
		"ispublic" => $ispublic
	);
}else{
	$condition = array(
		"uid" => __user_id__,
		"prop" => __user_prop__,
		"infoid" => $infoid,
		"type" => $type,
		"ispublic" => $ispublic
	);
}



$result = $myHouse->getSearchRentList($condition , $order , $p);
$totalpage = $myHouse->getSearchPage2($condition , __admin_rhhouse_num__);


$page->assign("indexcls" , "bfont");
$page->assign("rentlist" , $result);
$page->assign("order" , $order);
$page->assign("ispublic" , $ispublic);
$page->assign("r_page" , $p);
$page->assign("totalpage" , $totalpage);

$page->assign("selected2_2" , "selected");
if($ispublic==0){
	$page->assign("param" , "rh_up");
}else{
	$page->assign("param" , "rh_down");
}

require_once("agent_admin_left.php");

$page->output();


ob_end_flush();

?>
